const fs=require('fs');
let rs = fs.createReadStream("./1.txt");
let ws = fs.createWriteStream("./2.txt");
rs.pipe(ws);
rs.on("error",err=>{
  console.log("读取失败")
})
ws.on("finish",()=>{
  console.log("写入成功")
})

